<div class="row">
 <div class="span3 bs-docs-sidebar ">
 	<*include file="<*$controller*>/location.tpl"*>
  </div>
 
  <div class="span9">
   <div class="clearfix txtleft search span9" style="background-color:#f8f8f8; padding:10px; margin:10px 0px;"> 
	现在异常状态选项
	</div>	    
    <*if $state|@count neq 0*>  
       <table class="table table-condensed table-bordered table-hover span9"> 
        <tr class="success">   
           <td><strong>序号</strong></td>
           <td><strong>选项内容</strong></td>
           <td><strong>操作</strong></td>
        </tr>
        <*foreach from=$state item=a key =key name=foo*> 
        <tr>
           <td class="span1"><*$a.id*></td>
           <td class="span1"><*$a.state*></td>
           <td class="span1">
            <input type="button" class="btn btn-primary"  id="edit" value="编辑" onclick="window.location='/<*$controller*>/edit/id/<*$a.id*>'" >           
		   <*if $a.state*>		
                <input type="button" class="btn"  id="delete" value="删除" onclick="deleteit(<*$a.id*>)" >
           <*/if*>     
           </td>
        </tr>
        <*/foreach*>
      </table>
      <*else*>  
          没有信息！   
      <*/if*>  
    </div>

<script type="text/javascript"> 
function deleteit(id)
{
  if(confirm("确定要删除吗？")){
   window.location='/<*$controller*>/delete/id/'+id;
  }
} 
</script>
 </div> 